package com.atguigu.lease.web.admin.mapper;

import com.atguigu.lease.model.entity.ApartmentInfo;
import com.atguigu.lease.web.admin.vo.apartment.ApartmentDetailVo;
import com.atguigu.lease.web.admin.vo.apartment.ApartmentItemVo;
import com.atguigu.lease.web.admin.vo.apartment.ApartmentQueryVo;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

/**
* @author xiongkunYang
* @description 针对表【apartment_info(公寓信息表)】的数据库操作Mapper
* @createDate 2025-04-19 22:27:34
* @Entity com.atguigu.lease.model.entity.ApartmentInfo
*/
@Mapper
public interface ApartmentInfoMapper extends BaseMapper<ApartmentInfo> {

    /**
     * 根据条件分页查询公寓列表
     *
     * @param page 分页对象，用于封装分页信息和数据
     * @param queryVo 查询条件对象，包含各种查询参数
     * @return 填充了公寓信息的分页对象
     */
    IPage<ApartmentItemVo> selectApartmentItemPageByQuery(@Param("page") Page<ApartmentItemVo> page,
                                                          @Param("queryVo") ApartmentQueryVo queryVo);

    /**
     * 根据公寓ID查询公寓详细信息
     *
     * @param id 公寓ID
     * @return 包含公寓详细信息的VO对象
     */
    ApartmentDetailVo selectApartmentDetailById(Long id);
}




